<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
</head>

<style>

    /*p {*/
    /*    width: 100px;*/
    /*    height: 100px;*/
    /*    background-color: pink;*/
    /*    word-wrap: break-word; !* 强制单词换行 *!*/
    /*    word-break: break-all; !* 强制长单词断行 *!*/
    /*}*/


    p {
        width: 100px;
        height: 100px;
        background-color: pink;
        overflow: hidden; /* 隐藏超出部分 */
        text-overflow: ellipsis; /* 超出部分用省略号表示 */
        white-space: nowrap; /* 防止换行 */
    }


</style>
<body>

<p>fasdfasdfasdfasdfasdf</p>
</body>
</html>